package ArrayList_1;

import java.util.ArrayList;
import java.util.Iterator;
import java.util.Scanner;

public class demo2 {
    /**
     * 去除str1中出现的字符str2
     * @param args
     */
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String s1 = sc.nextLine();
        String s2 = sc.nextLine();
        ArrayList<Character> list1 = new ArrayList<>();

        for (int i = 0; i < s1.length(); i++) {
            if(!s2.contains(s1.charAt(i)+"")){
                list1.add(s1.charAt(i));
            }
        }
        Iterator<Character> it = list1.iterator();
        while (it.hasNext()){
            System.out.print(it.next()+"");
        }
    }
}
